<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
  <script src="lib/vue.js"></script>
</head>
<body>
  <div id="root" >
    <a :href="src | href" target="_blank">111</a>
  </div>
</body>
<script type="module">
  import VueFilters from "./lib/VueFilters.js";
  for (let key in VueFilters){
    Vue.filter(key,VueFilters[key]);
  }
  new Vue({
    el:"#root",
    data:{
      src:'baidu'
    },

    filters:{
      date(v){
        const time = new Date(v);
        return time.getFullYear()+"-"+
                (time.getMonth()+1).toString().padStart(2,0)+"-"+
                time.getDate().toString().padStart(2,0)+" "+
                time.getHours().toString().padStart(2,0)+":"+
                time.getMinutes().toString().padStart(2,0)+":"+
                time.getSeconds().toString().padStart(2,0);
      }
    }
  })
</script>
</html>